// 院校表
const sequelize = require( '../config.js')
const { DataTypes } = require('sequelize')

const schoolInfo = sequelize.define('school_info', {
    school_id: {
        type: DataTypes.INTEGER,
        primaryKey: true,
        autoIncrement: true,
    },
    school_name: {
        type: DataTypes.STRING,
        allowNull: false,
        comment: '学校名称'
    },
    school_city_name: {  
        type: DataTypes.STRING,
        allowNull: false,
        comment: "院校所在城市"
    },
    school_phone: {
        type: DataTypes.STRING,
        allowNull: false,
        comment: '院校负责人电话'
    },
    school_duty: {
        type: DataTypes.STRING,
        allowNull:false,
        comment: '院校负责人'
    },
    school_student_num: {
        type: DataTypes.INTEGER,
        allowNull:false,
        comment: "院校学生人数"
    },
    school_duty_position: {
        type: DataTypes.STRING,
        comment: "负责人职位"
    },
    school_logo:{
        type:DataTypes.STRING,
        comment:'学校logo'
    },
    school_menu_ids:{
        type:DataTypes.STRING,
        comment:'院校菜单'
    }
});

//   (async ()=>{
// 	await schoolInfo.sync({alter:true});
//   })()
  module.exports = schoolInfo
  